// 不需要保存tags 的页面
const whiteList = ['/login', '/404', '/401']

//是否需要保存
export const isTags = (path: string) => {
  return !whiteList.includes(path)
}

// 设置title
export const getTile = (route: any) => {
  let title = ''
  if (!route.meta) {
    const pathArr = route.path.split('/')
    title = pathArr[pathArr.length - 1]
  } else {
    title = route.meta.title
  }
  return title
}
